home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1992 June: ROMin Holiday / ADC Developer CD (1992-06) (''ROMin Holiday'')_iso / Developer Connection - 06-1992.iso / Developer Essentials / MPW Interfaces & Libraries / CIncludes / ToolUtils.h < prev    next >
Encoding:
C/C++ Source or Header  |  1992-01-29  |  2.8 KB  |  116 lines  |  [TEXT/MPS ]

  1.  
  2. /************************************************************
  3.  
  4. Created: Sunday, September 15, 1991 at 9:19 PM
  5.  ToolUtils.h
  6.  C Interface to the Macintosh Libraries
  7.  
  8.  
  9.   Copyright Apple Computer, Inc. 1985-1991
  10.   All rights reserved
  11.  
  12. ************************************************************/
  13.  
  14.  
  15. #ifndef __TOOLUTILS__
  16. #define __TOOLUTILS__
  17.  
  18. #ifndef __QUICKDRAW__
  19. #include <Quickdraw.h>
  20. #endif
  21.  
  22.  
  23. enum {
  24.  
  25.  sysPatListID = 0,
  26.  iBeamCursor = 1,
  27.  crossCursor = 2,
  28.  plusCursor = 3,
  29.  watchCursor = 4
  30. };
  31.  
  32. struct Int64Bit {
  33.  long hiLong;
  34.  long loLong;
  35. };
  36.  
  37. typedef struct Int64Bit Int64Bit;
  38.  
  39.  
  40. #ifdef __cplusplus
  41. extern "C" {
  42. #endif
  43. pascal Fixed FixRatio(short numer,short denom)
  44.  = 0xA869; 
  45. pascal Fixed FixMul(Fixed a,Fixed b)
  46.  = 0xA868; 
  47. pascal short FixRound(Fixed x)
  48.  = 0xA86C; 
  49. pascal StringHandle GetString(short stringID)
  50.  = 0xA9BA; 
  51. pascal long Munger(Handle h,long offset,const void *ptr1,long len1,const void *ptr2,
  52.  long len2)
  53.  = 0xA9E0; 
  54. pascal void PackBits(Ptr *srcPtr,Ptr *dstPtr,short srcBytes)
  55.  = 0xA8CF; 
  56. pascal void UnpackBits(Ptr *srcPtr,Ptr *dstPtr,short dstBytes)
  57.  = 0xA8D0; 
  58. pascal Boolean BitTst(const void *bytePtr,long bitNum)
  59.  = 0xA85D; 
  60. pascal void BitSet(void *bytePtr,long bitNum)
  61.  = 0xA85E; 
  62. pascal void BitClr(void *bytePtr,long bitNum)
  63.  = 0xA85F; 
  64. pascal long BitAnd(long value1,long value2)
  65.  = 0xA858; 
  66. pascal long BitOr(long value1,long value2)
  67.  = 0xA85B; 
  68. pascal long BitXor(long value1,long value2)
  69.  = 0xA859; 
  70. pascal long BitNot(long value)
  71.  = 0xA85A; 
  72. pascal long BitShift(long value,short count)
  73.  = 0xA85C; 
  74. pascal short HiWord(long x)
  75.  = 0xA86A; 
  76. pascal short LoWord(long x)
  77.  = 0xA86B; 
  78. pascal void LongMul(long a,long b,Int64Bit *result)
  79.  = 0xA867; 
  80. pascal Handle GetIcon(short iconID)
  81.  = 0xA9BB; 
  82. pascal void PlotIcon(const Rect *theRect,Handle theIcon)
  83.  = 0xA94B; 
  84. pascal PatHandle GetPattern(short patternID)
  85.  = 0xA9B8; 
  86. pascal CursHandle GetCursor(short cursorID)
  87.  = 0xA9B9; 
  88. pascal PicHandle GetPicture(short pictureID)
  89.  = 0xA9BC; 
  90. pascal Fixed SlopeFromAngle(short angle)
  91.  = 0xA8BC; 
  92. pascal short AngleFromSlope(Fixed slope)
  93.  = 0xA8C4; 
  94. StringHandle newstring(char *theString); 
  95. pascal void SetString(StringHandle theString,ConstStr255Param strNew)
  96.  = 0xA907; 
  97. pascal long DeltaPoint(Point ptA,Point ptB)
  98.  = 0xA94F; 
  99. pascal StringHandle NewString(ConstStr255Param theString)
  100.  = 0xA906; 
  101. pascal void ShieldCursor(const Rect *shieldRect,Point offsetPt)
  102.  = 0xA855; 
  103. pascal void GetIndString(Str255 theString,short strListID,short index); 
  104. void getindstring(char *theString,short strListID,short index); 
  105. pascal void ScreenRes(short *scrnHRes,short *scrnVRes)
  106.  = {0x225F,0x32B8,0x0102,0x225F,0x32B8,0x0104}; 
  107. pascal void GetIndPattern(Pattern thePat,short patternListID,short index); 
  108. void setstring(StringHandle theString,char *strNew); 
  109. void shieldcursor(const Rect *shieldRect,Point *offsetPt); 
  110. long deltapoint(Point *ptA,Point *ptB); 
  111. #ifdef __cplusplus
  112. }
  113. #endif
  114.  
  115. #endif
  116.